Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(MenuV2): add search feature in menu #4604

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

matthprost
Copy link
Collaborator

Summary

Type

  • Enhancement

Summarise concisely:

What is expected?

  • New prop searchable, when set to true a search bar will appear on the MenuV2. This can be useful for searching for a specific items quick. The searchbar is focused automatically when menu appear.
  • New prop hideOnClickItem: this is to replace function as children being used to close the menu when an item is clicked.
  • Global refactoring of the folder structure and addition of a provider needed for state management

Relevant logs and/or screenshots

Menu with prop searchable and hideOnClickItem set to true:

Screen.Recording.2024-12-19.at.12.23.47.mov

@matthprost matthprost added the enhancement New feature or request label Dec 19, 2024
@matthprost matthprost requested review from mhervouet and a team December 19, 2024 11:50
@matthprost matthprost self-assigned this Dec 19, 2024
@matthprost matthprost removed the request for review from a team December 19, 2024 11:50
@matthprost matthprost requested a review from lisalupi as a code owner December 19, 2024 11:50
Copy link

changeset-bot bot commented Dec 19, 2024

🦋 Changeset detected

Latest commit: 15cd2bc

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 3 packages
Name Type
@ultraviolet/ui Minor
@ultraviolet/form Patch
@ultraviolet/plus Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

Copy link

codecov bot commented Dec 30, 2024

Codecov Report

Attention: Patch coverage is 95.23810% with 7 lines in your changes missing coverage. Please review.

Project coverage is 87.49%. Comparing base (3103e43) to head (15cd2bc).
Report is 1 commits behind head on main.

Files with missing lines Patch % Lines
...kages/ui/src/components/MenuV2/components/Item.tsx 50.00% 6 Missing ⚠️
packages/ui/src/components/MenuV2/MenuProvider.tsx 92.85% 1 Missing ⚠️
Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main    #4604      +/-   ##
==========================================
+ Coverage   87.43%   87.49%   +0.05%     
==========================================
  Files         335      339       +4     
  Lines       12722    12822     +100     
  Branches     3520     3487      -33     
==========================================
+ Hits        11124    11219      +95     
- Misses       1598     1603       +5     
Files with missing lines Coverage Δ
packages/ui/src/components/MenuV2/MenuContent.tsx 100.00% <100.00%> (ø)
.../ui/src/components/MenuV2/__tests__/index.test.tsx 100.00% <100.00%> (ø)
...ages/ui/src/components/MenuV2/components/Group.tsx 100.00% <ø> (ø)
packages/ui/src/components/MenuV2/constants.ts 100.00% <100.00%> (ø)
packages/ui/src/components/MenuV2/helpers.ts 100.00% <100.00%> (ø)
packages/ui/src/components/MenuV2/index.tsx 100.00% <100.00%> (ø)
packages/ui/src/components/Tabs/TabMenuItem.tsx 100.00% <100.00%> (ø)
packages/ui/src/components/MenuV2/MenuProvider.tsx 92.85% <92.85%> (ø)
...kages/ui/src/components/MenuV2/components/Item.tsx 86.66% <50.00%> (ø)

... and 1 file with indirect coverage changes


Continue to review full report in Codecov by Sentry.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update c0f8849...15cd2bc. Read the comment docs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants